# Contributor: Leo <thinkabit.ukim@gmail.com>
# Maintainer: Leo <thinkabit.ukim@gmail.com>
pkgname=py3-treq
pkgver=20.4.1
pkgrel=0
pkgdesc="py3-requests-like API build on top of Twisted's HTTP client"
url="https://github.com/twisted/treq"
arch="noarch"
license="MIT"
depends="python3 py3-incremental py3-requests py3-six py3-twisted py3-attrs"
makedepends="py3-setuptools"
checkdepends="py3-httpbin py3-openssl py3-pytest py3-mock py3-service_identity"
source="$pkgname-$pkgver.tar.gz::https://github.com/twisted/treq/archive/release-$pkgver.tar.gz"
builddir="$srcdir/treq-release-$pkgver"

build() {
	python3 setup.py build
}

check() {
	rm -f src/treq/test/test_treq_integration.py
	python3 -m pytest
}

package() {
	python3 setup.py install --prefix=/usr --root="$pkgdir"
}

sha512sums="d08b95834ca02bb2c0f5b7c2306d8c4b4309939894c4f4eb61ed28c32258a5baa13ab7f1cf414b2c211fbb7a2964e033e45cbe3d9eb0020fd4bd80bb5845cbe5  py3-treq-20.4.1.tar.gz"
